package com.ysd.entity;

/**
 * 购物车类
 * 
 * @author dzj20
 *
 */
public class Cart {
	private Integer cid; // 编号
	private Integer uid; // 用户编号,外键
	private Integer bookId; // 书编号,外键
	private Integer number; // 数量
	private Integer purchaseOrNot; // 勾选状态

	private Integer Total_Price;

	public Integer getTotal_Price() {
		return Total_Price;
	}

	public void setTotal_Price(Integer total_Price) {
		Total_Price = total_Price;
	}

	private User user;
	private Books books;

	public Integer getCid() {
		return cid;
	}

	public void setCid(Integer cid) {
		this.cid = cid;
	}

	public Integer getUid() {
		return uid;
	}

	public void setUid(Integer uid) {
		this.uid = uid;
	}

	public Integer getBookId() {
		return bookId;
	}

	public void setBookId(Integer bookId) {
		this.bookId = bookId;
	}

	public Integer getNumber() {
		return number;
	}

	public void setNumber(Integer number) {
		this.number = number;
	}

	public Integer getPurchaseOrNot() {
		return purchaseOrNot;
	}

	public void setPurchaseOrNot(Integer purchaseOrNot) {
		this.purchaseOrNot = purchaseOrNot;
	}

	public User getUser() {
		return user;
	}

	public void setUser(User user) {
		this.user = user;
	}

	public Books getBooks() {
		return books;
	}

	public void setBooks(Books books) {
		this.books = books;
	}

	public Cart(Integer cid, Integer uid, Integer bookId, Integer number, Integer purchaseOrNot, User user,
			Books books) {
		super();
		this.cid = cid;
		this.uid = uid;
		this.bookId = bookId;
		this.number = number;
		this.purchaseOrNot = purchaseOrNot;
		this.user = user;
		this.books = books;
	}

	public Cart() {
		super();
	}

	@Override
	public String toString() {
		return "Cart [cid=" + cid + ", uid=" + uid + ", bookId=" + bookId + ", number=" + number + ", purchaseOrNot="
				+ purchaseOrNot + ", Total_Price=" + Total_Price + ", user=" + user + ", books=" + books + "]";
	}

	public Cart(Integer cid, Integer uid, Integer bookId, Integer number, Integer purchaseOrNot, Integer total_Price,
			User user, Books books) {
		super();
		this.cid = cid;
		this.uid = uid;
		this.bookId = bookId;
		this.number = number;
		this.purchaseOrNot = purchaseOrNot;
		Total_Price = total_Price;
		this.user = user;
		this.books = books;
	}

}